import cookie from "cookie";
export default fromNodeMiddleware(async (req, res, next) => {
  // getCookie(req,"token")
  let co = cookie.parse((req.headers.cookie + "") as any);
  // console.log(co);
  if (!co.token) {
    res.end("失败");
    return;
  }
  // console.log(req.headers.cookie);
  next();
});
